import Vue from 'vue'
import VueRouter from 'vue-router'


Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    alias: '',
    name: 'home',
    component: () => import('../views/Home.vue'),
  },
  {
    path: '/detailPage/:id',
    name: 'DetailPage',
    component: () => import('../views/DetailPage.vue'),
  },
  {
    path: '/',
    name: 'SignIn',
    component: () => import('../views/SignIn.vue'),
  },
  {
    path: '/',
    name: 'Register',
    component: () => import('../views/Register.vue'),
  },
  {
    path: '/comment/:id',
    name: 'Comment',
    component: () => import('../views/Comment.vue'),
  },
]

const router = new VueRouter({
  mode:'hash',
  routes
})

export default router
